<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8" %>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>
<body>
<center>
    <%
        String url = null;
        if (request.getParameter("url")!=null){
            url = request.getParameter("url");
        }else {
            url = (String)request.getAttribute("url");
        }
    %>
    <form action="/<%=url%>" method="post">
             <input type="hidden" name="id" value="${user.id}">
        姓名：<input type="text" name="name" value="${user.name}"><br>
        性别：<input type="radio" name="sex" value="男" ${user.sex.equals("男")?"checked":''}>男<input type="radio" name="sex" value="女" ${user.sex.equals("女")?"checked":''}>女<br>
        年龄：<input type="number" name="age" value="${user.age}">
        <input type="submit" value="提交">
    </form>
</center>
</body>
</html>